package com.lannuokeji.biz.ac.mapper;

import com.lannuokeji.biz.ac.entity.Department;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.pagination.Pagination;

/**
 * <p>
 * 部门管理 Mapper 接口
 * </p>
 *
 * @author lannuoTeck
 * @since 2018-03-17
 */
public interface DepartmentMapper extends BaseMapper<Department> {

	Department getInfo(@Param("id") Integer id);

	List<Department> page(Pagination page,@Param("name") String name, @Param("status") Integer status);

	@Update("update g_department set status = 2 where id=#{id}")
	boolean del(@Param("id") Integer id);
	
	@Select("select * from g_department where status=1")
	List<Department> getDepList();
}
